package com.yituo.mjworld.mvc.entity.web;

import javax.persistence.*;

@Entity
@Table(name = "user_info_record", schema = "web_mojianworld_server", catalog = "")
public class UserInfoRecord {

  private String userId;
  private String idCardImage1;
  private String idCardImage2;
  private String businessLicense;
  private String telPhone;
  private String moblie;
  private String address;

  @Id
  @Column(name = "userId", nullable = false, length = 36)
  public String getUserId() {
    return userId;
  }

  public void setUserId(String userId) {
    this.userId = userId;
  }

  @Basic
  @Column(name = "idCardImage1", nullable = true, length = 100)
  public String getIdCardImage1() {
    return idCardImage1;
  }

  public void setIdCardImage1(String idCardImage1) {
    this.idCardImage1 = idCardImage1;
  }

  @Basic
  @Column(name = "idCardImage2", nullable = true, length = 100)
  public String getIdCardImage2() {
    return idCardImage2;
  }

  public void setIdCardImage2(String idCardImage2) {
    this.idCardImage2 = idCardImage2;
  }

  @Basic
  @Column(name = "businessLicense", nullable = true, length = 100)
  public String getBusinessLicense() {
    return businessLicense;
  }

  public void setBusinessLicense(String businessLicense) {
    this.businessLicense = businessLicense;
  }

  @Basic
  @Column(name = "telPhone", nullable = true, length = 100)
  public String getTelPhone() {
    return telPhone;
  }

  public void setTelPhone(String telPhone) {
    this.telPhone = telPhone;
  }

  @Basic
  @Column(name = "moblie", nullable = true, length = 11)
  public String getMoblie() {
    return moblie;
  }

  public void setMoblie(String moblie) {
    this.moblie = moblie;
  }

  @Basic
  @Column(name = "address", nullable = true, length = 11)
  public String getAddress() {
    return address;
  }

  public void setAddress(String address) {
    this.address = address;
  }

  @Override
  public boolean equals(Object o) {
    if (this == o) return true;
    if (o == null || getClass() != o.getClass()) return false;

    UserInfoRecord that = (UserInfoRecord) o;

    if (userId != null ? !userId.equals(that.userId) : that.userId != null) return false;
    if (idCardImage1 != null ? !idCardImage1.equals(that.idCardImage1) : that.idCardImage1 != null) return false;
    if (idCardImage2 != null ? !idCardImage2.equals(that.idCardImage2) : that.idCardImage2 != null) return false;
    if (businessLicense != null ? !businessLicense.equals(that.businessLicense) : that.businessLicense != null)
      return false;
    if (telPhone != null ? !telPhone.equals(that.telPhone) : that.telPhone != null) return false;
    if (moblie != null ? !moblie.equals(that.moblie) : that.moblie != null) return false;
    if (address != null ? !address.equals(that.address) : that.address != null) return false;

    return true;
  }

  @Override
  public int hashCode() {
    int result = userId != null ? userId.hashCode() : 0;
    result = 31 * result + (idCardImage1 != null ? idCardImage1.hashCode() : 0);
    result = 31 * result + (idCardImage2 != null ? idCardImage2.hashCode() : 0);
    result = 31 * result + (businessLicense != null ? businessLicense.hashCode() : 0);
    result = 31 * result + (telPhone != null ? telPhone.hashCode() : 0);
    result = 31 * result + (moblie != null ? moblie.hashCode() : 0);
    result = 31 * result + (address != null ? address.hashCode() : 0);
    return result;
  }
}
